<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        // localStorage 存储类型是string
        let geo = {
            lat:'28.682',
            lng:'123.3212'
        }
        localStorage.setItem('geo',JSON.stringify(geo))
        // console.log()
        // localStorage.setItem('ls_name','www'); // 一直存在
        // sessionStorage.setItem('ss_name','xxx'); // 会话中在，关闭浏览器删除
    </script>
</body>
</html>